package com.lc.YYGH.hosp.repository;

import com.lc.YYGH.model.hosp.Hospital;
import org.springframework.data.mongodb.repository.MongoRepository;
import org.springframework.stereotype.Repository;

import java.util.List;

@Repository
public interface HospitalRepository extends MongoRepository<Hospital,String > {
     //根据hoscode来查询
    Hospital findByHoscode(String hoscode);

//根据医院名模糊查询
    List<Hospital> findByHosnameLike(String hosname);
    //Hospital getHospitalByHoscode(String hoscode);//判断是否存在数据
}
